package com.biz.primus.ms.thirdlogin.dao.repository;

import com.biz.primus.model.thirdlogin.enums.OAuthTypes;
import com.biz.primus.ms.base.jpa.repository.CommonJpaRepository;
import com.biz.primus.ms.thirdlogin.dao.po.OAuthMember;

import java.util.List;

/**
 * @author jun.liu
 * @date 2017/9/29
 */
public interface OAuthMemberRepository extends CommonJpaRepository<OAuthMember, Long>
{

    OAuthMember findByOAuthTypeAndOAuthIdAndMemberId(OAuthTypes oAuthType, String oAuthId, Long memberId);

    OAuthMember findByOAuthTypeAndOAuthId(OAuthTypes oAuthType, String oAuthId);

    List<OAuthMember> findByMemberId(Long memberId);
}
